﻿using System;
using System.Collections.Generic;
using System.Text;

using SH;

namespace MTS
{

	public interface ImtSMSServerCallback : ImtCallback
	{
		const int _classID = 4532;
		const string _interfaceName = "mtSMSServerCallback";
		const int SMSServerLogOn = 10;
		const int SMSServerLogOut = 11;
		const int SMSServerGetCredential = 12;
		const int SMSServerEventNotify = 13;
		const int SMSServerOperationLogNotify = 14;
		const int SMSServerErrorNotify = 15;
		const int SMSServerStatusNotify = 16;
		const int SMSServerGetResourceString = 17;

		const int SMSServerReconComplete = 18;
		const int SMSServerAutoStatResult = 19;
		const int SMSServerPerformanceVerifResult = 20;

		const int SMSServerRecognizeComplete = 21;
		const int SMSServerNotifyRcgAlgInfo = 22;

		const int SMSServerStorageComplete = 23;
		const int SMSServerDeleteImageResult = 24;
		const int SMSServerSaveImageResult = 25;

		//from everyone
		[mtFuncID("SMSServerLogOn", SMSServerLogOn)]
		public shErrorCode OnLogOn(mtLogOnInfo logonInfo, out mtCredential crd);

		[mtFuncID("SMSServerLogOut", SMSServerLogOut)]
		public shErrorCode OnLogOut(mtLogOnInfo logonInfo, mtCredential crd);

		[mtFuncID("SMSServerGetCredential", SMSServerGetCredential)]
		public shErrorCode OnGetCredential(string token, out mtCredential crd);

		[mtFuncID("SMSServerEventNotify", SMSServerEventNotify)]
		public shErrorCode OnEventNotify(uint nRank, emStationType st, emProgramType pt, uint nUserId, string userName, string stationName, string programName, uint nEventId, uint nEventSubId, string des, ulong nTimeStamp);

		// add by tangyetao 2020/07/09  新的操作日志接口
		[mtFuncID("SMSServerOperationLogNotify", SMSServerOperationLogNotify)]
		public shErrorCode OnOperationLogNotify(uint nRank, emStationType st, emProgramType pt, uint nUserId, string userName, string stationName, string programName, uint nEventId, uint nEventSubId, mtOperationInfo operationinfo, ulong nTimeStamp);

		[mtFuncID("SMSServerErrorNotify", SMSServerErrorNotify)]
		public shErrorCode OnErrorNotify(string token, uint nErrorCode);

		[mtFuncID("SMSServerStatusNotify", SMSServerStatusNotify)]
		public shErrorCode OnStatusNotify(string token, ulong nStatusCode);

		[mtFuncID("SMSServerGetResourceString", SMSServerGetResourceString)]
		public shErrorCode OnGetResourceString(string token, string lang, List<uint> vecrId,out List<string> vecResources);

		//from RCC
		[mtFuncID("SMSServerReconComplete", SMSServerReconComplete)]
		public shErrorCode OnReconComplete(string token, mtReconComplete info);

		[mtFuncID("SMSServerAutoStatResult", SMSServerAutoStatResult)]
		public shErrorCode OnAutoStatResult(string token, mtAutoStatResult info);

		[mtFuncID("SMSServerPerformanceVerifResult", SMSServerPerformanceVerifResult)]
		public shErrorCode OnPerformanceVerifResult(string token, mtVerifCalibResult info);

		//from RCG
		[mtFuncID("SMSServerRecognizeComplete", SMSServerRecognizeComplete)]
		public shErrorCode OnRecognizeComplete(string token, mtRecognizeComplete info);

		[mtFuncID("SMSServerNotifyRcgAlgInfo", SMSServerNotifyRcgAlgInfo)]
		public shErrorCode OnNotifyRcgAlgInfo(string token, mtRecognizeAlgorithm info);    //上报算法信息

		//from RCS

		[mtFuncID("SMSServerStorageComplete", SMSServerStorageComplete)]
		public shErrorCode OnStorageComplete(string token, mtStorageComplete info);

		[mtFuncID("SMSServerDeleteImageResult", SMSServerDeleteImageResult)]
		public shErrorCode OnNotifyDeleteImageResult(string token, mtDeleteImageResult result);

		[mtFuncID("SMSServerSaveImageResult", SMSServerSaveImageResult)]
		public shErrorCode OnNotifySaveImageResult(string token, mtSaveImageResult result);

	};

	public interface ImtSMSServer : Imt
	{

		//to Everyone
		public shErrorCode UpdateCredential(mtCredential crd);

		// to RCS
		public shErrorCode DeleteImage(mtDeleteImageDemand req, out mtDeleteImageReply rsp);

		public shErrorCode SaveImage(mtSaveImageRequest req, out mtSaveImageResponse rsp);

		public shErrorCode GetStorageCapacity(out mtStorageCapacityInfo info);

		// to RCG
		public shErrorCode SetRecognizeAlgorithm( mtRecognizeAlgorithm info); //设置算法信息

		//to RCC
	//	public shErrorCode SetScanMode(string token, mtScanMode info);                         // 设置扫描模式

	//	public shErrorCode NotifyPerformanceVerif(string token, mtVerifCalibCmd info);         // 通知开始性能检验或标定

	}


}
